#[derive(Debug)]
struct Point<T, U>{
    x: T,
    y: U
}

impl <T, U> Point<T, U>{
    fn mixup<V, W>(self, other: Point<V, W>)->Point<V, U>{
        Point{
            x: other.x,
            y: self.y
        }
    }
}

fn main() {
    let p1 = Point{
        x: 5,
        y: 10.4
    };

    let p2 = Point{
        x: "Hello",
        y: 'C'
    };
    let p3 = p1.mixup(p2);
    println!("{:?}", p3);
}
